<!doctype html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Document</title>
    <meta charset="utf-8">
    <title></title>
    <meta name="viewport" content="width=1000, initial-scale=1.0, maximum-scale=1.0">
    <!-- Loading Bootstrap -->
    <link href="Public/Admin/Flat/dist/css/vendor/bootstrap.min.css" rel="stylesheet">
    <!-- Loading Flat UI -->
    <link href="Public/Admin/Flat/dist/css/flat-ui.css" rel="stylesheet">
    <link rel="shortcut icon" href="Public/Admin/Flat/img/favicon.ico">
    <!-- HTML5 shim, for IE6-8 support of HTML5 elements. All other JS at the end of file. -->
    <!--[if lt IE 9]>
    <script src="dist/js/vendor/html5shiv.js"></script>
    <script src="dist/js/vendor/respond.min.js"></script>
    <![endif]-->
    
    <!-- 气泡弹窗 -->
    <script type="text/javascript" src="Public/uploadify/jquery-1.8.2.min.js"></script>
    <link rel="stylesheet" type="text/css" href="{{__PUBLIC__}}/Home/js/hdjs.css" />
    <script src="{{__PUBLIC__}}/Home/js/hdjs.min.js" type="text/javascript" charset="utf-8"></script>
</head>
<body>
    <style type="text/css">
        .form-group{
            margin-bottom: 5px;
        }
        .form-group label{
            font-size: 16px;
            cursor: pointer;
        }
        .form-group label input{
            width: 15px;
            height: 15px;
        }
        .bigbox{
            border: 2px solid #bdc3c7;
            border-radius: 6px;
            margin-bottom: 10px;
            padding: 10px;
        }
    </style>
        <div class="alert alert-success">编辑 {{$roleData['name']}} 角色</div>
        <form action="" method="post" onsubmit="return hd_submit(this,'{{U('Rbac/editrole')}}','{{U('Rbac/authority',array('aid'=>Q('get.aid')))}}')">
            <div  class="form-group">
                <label for="rolename">角色名称：</label>
                <input class="form-control "  type="text" name="name" value="{{$roleData['name']}}" required=""/>
            </div>
            <label for="rolename">角色权限：</label>
            <div class="bigbox">
                {{foreach from="$nodeData" value="$value"}}
                <div  class="form-group" onselectstart="return false">
                    <label>
                        {{$value['id']}}-{{$value['_name']}}--{{$value['title']}}
                        {{if value="$value['level']==3"}}
                            <input type="checkbox" name="level3[]" value="{{$value['id']}}" {{if value="in_array($value['id'],$nids)"}}checked{{endif}}/>
                        {{endif}}
                    </label>
                </div>
                {{endforeach}}
            </div>
            <!-- 角色id隐藏域 -->
            <input type="hidden" name="rid" value="{{$roleData['id']}}">
            <input class="btn btn-primary btn-block" type="submit" value="确认编辑" />
        </form>


</body>
</html>
